home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 8844 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.8 KB

  1. Path: news.orl.mmc.com!woodcock
  2. From: woodcock@escmail.orl.mmc.com (Steve Woodcock)
  3. Newsgroups: comp.lang.c
  4. Subject: Data Name to Pointer Question
  5. Date: 6 Mar 1996 17:27:07 GMT
  6. Organization: Martin Marietta
  7. Message-ID: <4hkhtb$epm@theopolis.orl.mmc.com>
  8. NNTP-Posting-Host: 141.240.50.90
  9. X-Newsreader: TIN [version 1.2 PL2]
  10.  
  11. Hello All:
  12.  
  13.  
  14.    Apologies in advance is this is so mind-bogglingly simple that I'm
  15. somehow missing it.
  16.  
  17.    I have a data file containg the name of a structure called
  18. "process one", as such
  19.  
  20. #
  21. # comments
  22. #
  23. process_one
  24. #
  25. # comments
  26.  
  27.    Over in the program itself, "process one" is a data structure filled
  28. with information.
  29.  
  30.    Is there a way for me to convert the string "process one" that I read
  31. in from the data file to a pointer pointing to the actual structure
  32. "process one"?  Essentially, I want to turn the contents of this string
  33. variable into the *name* of the variable I want to access.
  34.  
  35. Steve
  36.  
  37. +=============================================================================+
  38. |                                                           _                 |
  39. | Steven Woodcock                                     _____C .._.             |
  40. | Senior Software Engineer, Gameware             ____/     \___/              |
  41. | Lockheed Martin Information Systems Group     <____/\_---\_\    "Ferretman" |
  42. | Phone:      719-597-5413                                                    |
  43. | E-mail:     woodcock@escmail.orl.mmc.com (Work), swoodcoc@cris.com (Home)   |
  44. | Web:        http://www.cris.com/~swoodcoc/ai.html    (Games AI page)        |
  45. |             http://www.cris.com/~swoodcoc/steve.html (Boring Steve Stuff)   |
  46. | Disclaimer: My opinions in NO way reflect the opinions of                   |
  47. |             the Lockheed Martin Information Systems Group                   |
  48. +=============================================================================+
  49.